#ifndef INFINITY_PHYSICS_OBJECT_H
#	define INFINITY_PHYSICS_OBJECT_H

#include "shapes.h"

namespace infinity {

class ServicePhysics;

	namespace physics {

struct Shape
{
public : //! @name Types definitions
	//! @{
	enum Type
	{
		Type_Sphere
	};
	//! @}

	union
	{
		Sphere sphere;
	};

	Type type;
};

class Object
{
public : //! @name Commands
	//! @{
	void applyImpulse(const Vector3f& impulse);
	//! @}

public : //! @name Setup
	//! @{
	void setPosition(const Vector3f& position);
	void setTransform(const Matrix4f& transform);
	//! @}

public : //! @name State
	//! @{
	const Matrix4f& getTransform() const ;
	//! @}

protected : //! @name Construction & Destruction
	//! @{
	friend class ::infinity::ServicePhysics;

	Object();
	virtual ~Object();
	//! @}

private : //! @name Data
	//! @{
	Matrix4f m_transform;
	Shape m_shape;
	Vector3f m_velocity; // m.s-1
	//! @}
};

	} // namespace physic
} // namespace infinity

#include "physicsobject.inl"

#endif // !INFINITY_PHYSICS_OBJECT_H
